/* application state */
#define APP_INITING			0
#define APP_INIT 			1
#define APP_READY			2
#define APP_HUB_READY		3
#define APP_DEV1_WAIT		4
#define APP_TERM			100
int estado 			= APP_INITING;

/* Estructuras */
struct passingdata {
	char text[6144];
	void* p;
	unsigned int timeout;
	unsigned int status;
};

/* Variables */
struct passingdata *pdata;
struct passingdata res;

/* Funciones */
void resetdata(struct passingdata *res) { memset(res,0,sizeof(struct passingdata)); }

/* system */
u32 k1;
#define k1s k1 = pspSdkSetK1(0)
#define k1r pspSdkSetK1(k1)